package com.github.kotvertolet.youtubejextractor.models.newModels;

import com.google.gson.annotations.SerializedName;
import ohos.utils.Parcel;
import ohos.utils.Sequenceable;

import java.io.Serializable;

public class Miniplayer implements Sequenceable, Serializable {

    @SerializedName("miniplayerRenderer")
    private MiniplayerRenderer miniplayerRenderer;


    public static final Sequenceable.Producer<Miniplayer> CREATOR = new Producer<Miniplayer>() {
        @Override
        public Miniplayer createFromParcel(Parcel parcel) {
            // Initialize an instance first, then do customized unmarshlling.
            Miniplayer miniplayer = new Miniplayer();
            miniplayer.unmarshalling(parcel);
            return miniplayer;
        }
    };
   
    @Override
    public boolean marshalling(Parcel parcel) {
        parcel.writeSequenceable(this.miniplayerRenderer);
        return true;
    }

    @Override
    public boolean unmarshalling(Parcel parcel) {
        parcel.readSequenceable(this.miniplayerRenderer);
        return true;
    }

    @Override
    public String toString() {
        return "Miniplayer{" +
                "miniplayerRenderer=" + miniplayerRenderer +
                '}';
    }

    public MiniplayerRenderer getMiniplayerRenderer() {
        return miniplayerRenderer;
    }

    public void setMiniplayerRenderer(MiniplayerRenderer miniplayerRenderer) {
        this.miniplayerRenderer = miniplayerRenderer;
    }
}
